<?php
USE_PAGE('panier');
class PagePanier_adresse extends Page
	{
	protected function build()
		{
/*
		$usr = Bills_customers_login::getCurrentUser();
		$b = $this->add( new Bills('BILL') );
		if(isset($usr) && !(Bills::hasAddresses()))
			{
			Bills::setUser($usr);
			}
		$f = $b->buildForm('formBILL');
		$b->doNotAdd();
*/
		$f = $this->add(new Pages_Html('MTM'));
		$f->setFilter('f_status=1 and f_menu_id=1');
		}
		
		
	public function handleEvent( $event, $source, $params ) {
		//parent::handleEvent( $event, $source, $params );
		if($event=='addrecord' || ($event=='reload' && $params==2))
			{
			$this->loadWithMessage('/panier-resume','Adresses prises en compte');
			die();
			}
		}

	protected function getPageUrl() { return '/panier-adresse'; }
	protected function getBreadcrumbTitle() { return 'Choix des adresses'; }
	protected function getPageParent() { return 'PagePanier'; }
	}
?>